#pragma once

#define MAXREQUEST 2048

typedef enum {
    REQ_LOGIN = 1,
    REQ_REGISTER,
    REQ_CHECK,
    REQ_UPLOAD_FILE,
    REQ_UPLOAD_CHUNK,
    REQ_DOWNLOAD_FILE,
    // ...
} RequestType;

typedef struct {
    int type;
    int length;     // value内容的长度
    char value[MAXREQUEST];
} Request;
